<template>
  <div id="DropDown">
    <el-popover trigger="hover" width="300" popper-class="popoverStyle">
      <template #reference>
        <span style="margin-right: 16px">{{
          store.getters.user.userInfo.nick
        }}</span>
      </template>
    </el-popover>
  </div>
</template>

<script setup>
import { useStore } from 'vuex';
const store = useStore();
</script>

<style lang="scss" scoped>
#DropDown {
  width: 300px;
  height: 500px;
  //   padding: 15px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  position: absolute;
  z-index: 999;

  // left: -135px;
  background: #fff;

  .header {
    padding: 15px;
    display: flex;

    .left {
      border-radius: 50%;

      img {
        width: 50px;
        border-radius: 50%;
      }
    }

    .mid {
      margin: 0 60px 0 20px;
    }
  }

  .isVip {
    background: #fdecd2;
    height: 35px;
    padding: 0 15px;
    line-height: 35px;
    margin: 0 15px;
    border-radius: 4px;
  }

  .tab-box {
    height: 40px;
    text-align: center;
    border-top: 1px solid #f2f2f2;
    border-bottom: 1px solid #f2f2f2;
    line-height: 40px;

    .tab-left {
      width: 50%;
      height: 100%;

      border-right: 1px solid #f2f2f2;
    }

    .tab-left {
      width: 50%;
      height: 100%;
    }
  }

  .login-out {
    padding: 15px;
    margin: 10px;
    border-top: 1px solid #f2f2f2;
    // border-bottom: 1px solid #f2f2f2;;
  }

  .triangle-up {
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-right: 8px solid transparent;
    border-left: 8px solid transparent;
    border-bottom: 8px solid #fff;
    position: absolute;
    top: -16px;
    left: 50%;
  }
  .isActive {
    background: var(--background-color);
    color: #fff !important;
  }
  .items {
    // background: red;
    margin: 10px 0;
    padding: 13px;

    &:hover {
      // background: var(--active-text);
      color: var(--color-text);
    }
  }
}
</style>
